package ModelLayer;

import java.util.ArrayList;
/**
 * The rent class is a class with the purpose of linking a person and copy together to create an agrrement.
 */

public class Rent
{
    private int id;
    private String date;
    private int period;
    private String status;
    private Copy copyRented;
    private Person person;

    public Rent(int id, String date, int period, Copy copyRented, Person person)
    {
        this.id = id;
        this.date = date;
        this.period = period;
        status = "Loaned out";
        this.copyRented = copyRented;
        this.person = person;
    }
    
    /**
     * Get methods
     */
    
    /**
     * getId returns id
     */
    
    public int getId()
    {
        return id;
    }
    /**
     * getDate returns date
     */
    
    public String getDate()
    {
        return date;
    }
    
    /**
     * getPeriod returns period
     */
    
    public int getPeriod()
    {
        return period;
    }
    
    /**
     * getStatus returns status
     */
    
    public String getStatus()
    {
        return status;
    }
    
    /**
     * getCopyRented returns the copy object connected to the rented object
     */
    
    public Copy getCopyRented()
    {
        return copyRented;
    }
    
    /**
     * getPerson returns a person
     */
    
    public Person getPerson()
    {
        return person;
    }
    
    /**
     * Set methods
     */
    
    /**
     * setId changes Id
     */
    
    public void setId(int id)
    {
        this.id = id;
    }
    
    /**
     * setDate changes date
     */
    
    public void setDate(String date)
    {
        this.date = date;
    }
    
    /**
     * setPeriod changes period
     */
    
    public void setPeriod(int period)
    {
        this.period = period;
    }
    
    /**
     * setStatus changes status
     */
    
    public void setStatus(String status)
    {
        this.status = status;
    }
    
    /**
     * setCopyRented changes the object copyRented
     */
    
    public void setCopyRented(Copy copyRented)
    {
        this.copyRented = copyRented;
    }
    
    /**
     * setPerson changes the person
     */
    
    public void setPerson(Person person)
    {
        this.person = person;
    }
    
    
    
   
}
